
<?php 
require_once('./admin/View/video/inc_admin.php');
 ?>
<div id="content">

	<div class="inner" style="min-height:1200px;">
		<div class="row">
			<div class="col-lg-12">

<?php 



$id=$_GET['id'];
$sql="select * from videos where vid={$id}";
$result=mysql_query($sql) or die('查询失败！'.mysql_error());
$row=mysql_fetch_assoc($result);
//var_dump($row);
$videoname=$row['videoname'];
$tid=$row['tid'];
$pic='upload/'.$row['pic'];
$intro=$row['intro'];
$address=$row['address'];

//将查询结果显示在表单中 
?>

				<div class="container-fluid col-sm-offset-1 col-md-10">
					<form method="post" action="index.php?c=video&m=update" enctype="multipart/form-data">
						<table align="center" border="1" width=500 class="table table-bordered">
							<caption>
								<h2 align="center"> <font color="green">请修改视频信息</font>
								</h2>
							</caption>
							<input type="hidden" name="id" value=<?php echo $id?>>
							<tr class="success">
							
								<td>视频名称</td>
								<td>
									<input type="text" name="videoname" size=30 value=<?php echo $videoname;?>></td>
							</tr>
							
				
							
							<tr >
								<td width=150>视频类型</td>
								<td>
									<select name="tid">
										
										<option value="1"<?php if($tid=='1') echo 'selected'; ?>>电视剧</option>
										<option value="2"<?php if($tid=='2') echo 'selected'; ?>>动漫</option>
										<option value="3"<?php if($tid=='3') echo 'selected'; ?>>悬疑</option>
										<option value="4"<?php if($tid=='4') echo 'selected'; ?>>惊悚</option>
										<option value="5"<?php if($tid=='5') echo 'selected'; ?>>爱情</option>
										<option value="6"<?php if($tid=='6') echo 'selected'; ?>>古装</option>
										<option value="7"<?php if($tid=='7') echo 'selected'; ?>>都市</option>
									</select>
								</td>
								<tr class="success">
								<td width=150>视频海报</td>
								<td>
									原海报:        <img src='<?php echo $pic;?>
									' width=120 height=130 class="img-rounded">
									<input type="file" name="pic"></td>
							</tr>
							</tr>
							<tr >
								<td width=150>视频简介</td>
								<td>
									<textarea name="intro" cols="40" rows="5">
										<?php echo $intro;?></textarea>
								</td>
							</tr>
						<tr class="success">
								<td width=150>下载地址</td>
								<td>
								<input type="text" name="address" size=30 value=<?php echo $address;?>></td>
								
							</tr>
							<tr >
								<td width=150></td>
								<td>
									<input type="submit" value="更新" class="btn btn-info"></td>
									
							</tr>
						</table>
                        </form>
					</div>
				</div>
			</div>

		</div>

	</div>
	<!--END PAGE CONTENT -->

	<!--END MAIN WRAPPER -->

	<!-- FOOTER -->
	<div id="footer">
		<p>&copy;  binarytheme &nbsp;2014 &nbsp;</p>
	</div>
	<!--END FOOTER -->
	<!-- GLOBAL SCRIPTS -->
	<script src="assets/plugins/jquery-2.0.3.min.js"></script>
	<script src="assets/plugins/bootstrap/js/bootstrap.min.js"></script>
	<script src="assets/plugins/modernizr-2.6.2-respond-1.1.0.min.js"></script>
	<!-- END GLOBAL SCRIPTS -->

	<!-- END BODY-->



	
</body>
</html>